# from progressive.bar import Bar  # pip install progressive
from django.core.management.base import BaseCommand, CommandError
from django.db import models
# from placeholders import *
import os

POSITION = 521025


class Command(BaseCommand):
    i = 100000000000
    # 创建一个空list

    r = list()

    # 添加元素2
    r.append(2)

    # 从3开始挨个筛选
    for a in range(3, i):
        b = False

        # 用a除以小于a的质数b
        for b in r:
            if a % b == 0:
                b = False
                break
            else:
                b = True
        if b == True:
            r.append(a)
            print(len(r))

        if len(r) == 521025:
            break
    print(r[-1])
